import cv2 as cv
import numpy as np


def main():
    filePath = '../data/jWithWhiteNoiseLeft.png'
    img = cv.imread(filePath, 0)
    kernel = np.ones((5, 5), np.uint8)
    opening = cv.morphologyEx(img, cv.MORPH_OPEN, kernel)
    cv.imshow('img', img)
    cv.imshow('opening', opening)
    cv.waitKey(0)
    cv.destroyAllWindows()


if __name__ == "__main__":
    main()
